package dyy.zc.computergradeexam;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.LinearLayout;
import android.widget.TextView;

public class BianChengActivity extends AppCompatActivity implements View.OnClickListener {
    private TextView title;
    private TextView tvQuestion;
    private TextView tvAnswerArea;
    private TextView tvShowAnswer;
    private LinearLayout llAnswerArea;
    private LinearLayout llExplanArea;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_bian_cheng);

        initView();
        initData();

    }

    private void initView() {
        title = (TextView) findViewById(R.id.top_tv_title);
        tvQuestion = (TextView) findViewById(R.id.tv_question);
        tvAnswerArea = (TextView) findViewById(R.id.tv_Answer);
        tvShowAnswer = (TextView) findViewById(R.id.tv_ShowAnswer);
        llAnswerArea = (LinearLayout) findViewById(R.id.ll_AnswerArea);
        llExplanArea = (LinearLayout) findViewById(R.id.ll_ExplainArea);

        title.setText("查看题目");
        tvShowAnswer.setOnClickListener(this);
    }

    private void initData() {

    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.tv_ShowAnswer:
                llAnswerArea.setVisibility(View.VISIBLE);
                llExplanArea.setVisibility(View.VISIBLE);
                break;
        }
    }
}
